home *** CD-ROM | disk | FTP | other *** search
- /*
- File: SampleLibrary.h
-
- Contains: Interface for everything that the CSampleLibrary exports including
- the functions of the traffic light function set.
-
- Copyright: © 1993 by Apple Computer, Inc., all rights reserved.
-
- */
-
- #ifndef __SAMPLELIBRARY__
- #define __SAMPLELIBRARY__
-
- #ifndef __TYPES__
- #include <Types.h>
- #endif
-
- /*————————————————————————————————————————————————————————————————————————————————————
- DEFINITIONS AND CONSTANTS
- ————————————————————————————————————————————————————————————————————————————————————*/
-
- #define rWindow 128 /* application's window */
- #define rStopRect 128 /* rectangle for Stop light */
- #define rGoRect 129 /* rectangle for Go light */
-
- #define mLight 131 /* Light menu */
- #define iStop 1
- #define iGo 2
-
- // if k<functionsetname>ID is declared, it will be used as default function set id
- // when the shared library is built.
-
- #define kTrafficLightLibID "slm:samp$CTrafficLightLib"
- #define kTrafficLightFunctionSet "slm:samp$CTrafficLightFunctionSet,1.1"
-
- /*————————————————————————————————————————————————————————————————————————————————————
- FunctionSet routines
- ————————————————————————————————————————————————————————————————————————————————————*/
-
- OSErr NewTrafficLight();
- void FreeTrafficLight();
- Boolean GetLightState();
- void SetLightState( Boolean newState );
- void DrawLight();
- void AdjustTrafficLightMenus( Boolean activate );
- void DoTrafficLightMenuCommand( short menuItem );
-
- #endif